Skip to content

feat: add resolver-backed extension lifecycle API - #5

Merged
m-mdy-m merged 13 commits into
mainfrom
feature/resolver-backed-extension-lifecycle
Nov 6, 2026
Merged

m-mdy-m merged 13 commits into
mainfrom
feature/resolver-backed-extension-lifecycle

Conversation

@m-mdy-m

@m-mdy-m m-mdy-m commented Nov 6, 2026

Copy link
Copy Markdown
Member

Summary

Adds a trusted Runtime embedding API for extensions whose source is provided by the Backend-owned, extension-scoped module resolver.

Implemented

  • Add Manager:load_resolved(name, config, options), which resolves the entry module init, keeps nested require within the same owning extension namespace and records the source as resolver.
  • Add Runtime:load_extension, Runtime:unload_extension and Runtime:list_extensions.
  • Keep lifecycle APIs off the Frontend Protocol command surface. Remote editing clients do not acquire permission to load local code.
  • Reject path-like extension names and nested module names before invoking the resolver.
  • Cover entry + nested module loading, returned metadata, unload cleanup, resolver-disabled failure, missing entry and path traversal in Runtime integration tests.
  • Document the API and its Backend-side security prerequisites.

Security / ownership boundary

Runtime validates namespace identifiers but does not access the filesystem. A real Backend resolver still must implement canonical path confinement, symlink/reparse-point protection, bounded reads, and Lua owner-thread delivery. This PR does not claim that the Backend resolver is implemented or that CDIN has live plugin activation end-to-end.

The lifecycle API is intentionally a trusted embedding surface. It is not exposed as request.command because there is not yet a product administrative authorization model for remote plugin management.

Verification

  • Runtime CI on this PR.
  • Review API semantics and compatibility.
  • Backend integration remains tracked separately in Backend issue #14.

Related

@m-mdy-m
m-mdy-m marked this pull request as ready for review November 6, 2026 08:31
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-06T08:31:33.472953Z
We couldn’t complete this review. Comment @codex review to try again.
bb1674d Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@m-mdy-m
m-mdy-m merged commit c57bb5d into main Nov 6, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant